1. Field of the Invention
The present invention generally relates to data processing and more particularly to managing access to data in a database.
2. Description of the Related Art
Databases are computerized information storage and retrieval systems. A relational database management system is a computer database management system (DBMS) that uses relational techniques for storing and retrieving data. The most prevalent type of database is the relational database, a tabular database in which data is defined so that it can be reorganized and accessed in a number of different ways.
Regardless of the particular architecture, in a DBMS, a requesting entity (e.g., an application or the operating system) demands access to a specified database by issuing a database access request. Such requests may include, for instance, simple catalog lookup requests or transactions and combinations of transactions that operate to read, change and add specified records in the database. These requests are made using high-level query languages such as the Structured Query Language (SQL). Illustratively, SQL is used to make interactive queries for getting information from and updating a database such as International Business Machines' (IBM) DB2, Microsoft's SQL Server, and database products from Oracle, Sybase, and Computer Associates. The term “query” denominates a set of commands for retrieving data from a stored database. Queries take the form of a command language that lets programmers and programs select, insert, update, find out the location of data, and so forth.
Any requesting entity, including applications, operating systems and, at the highest level, users, can issue queries against a database to retrieve one or more required data items. The required data items are persistently stored in the database and can thus be accessed multiple times by each authorized requesting entity. However, in particular cases it can be desirable to make a specific data item available only for a limited number of accesses. For instance, assume a given company that maintains a database that provides delivery status information to clients. Assume further that the available storage capacity of the database is restricted. To this end, the size of the database must be kept small and, therefore, each client of the company is allowed to access particular delivery status information only a single time. Thus, when the corresponding client has accessed the particular delivery status information, this information is deleted from the database in order to economize storage capacity. Subsequently, when new delivery status information is available for the corresponding client, he/she may again access this information only a single time. Thus, the size of the database can be managed accurately.
Implementing such a schema that only allows a limited number of accesses to data items stored in a conventional database requires implementation of a suitable programming logic. The programming logic would need to monitor access to the delivery status information and trigger deletion thereof when a corresponding access to the information has occurred. However, implementation of such a programming logic is a complex and time-consuming task and requires a detailed understanding of the underlying database.
Therefore, there is a need for an efficient technique for managing data in a database that should be available for a limited number of accesses.